<script setup>
import WIcon from '../../w-icon.vue'
const props = defineProps({
  loadText: {
    type: String
  },
  bgColor: {
    type: String,
    default: '#DDDDDD'
  },
  color: {
    type: String,
    default: '#1E90FF'
  }
})
</script>

<template>
  <div class="bwy-loading" :style="{backgroundColor: bgColor}">
    <w-icon name="loading" size="20" :color="color" />
    <span class="loading-Text">{{ loadText || '加载中...' }}</span>
  </div>
</template>

<style lang="scss">
.bwy-loading {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  position: absolute;
  left: 0;
  top: 0;
}
.loading-Text {
  font-size: 13px;
  letter-spacing: 1px;
  margin-left: 8px;
}
</style>
